#include <iostream>
#include <algorithm>

using namespace std;

void display_array(int *array, int len)
{
    cout << "[";
    for (int i=0; i<len; i++)
    {
        cout << array[i];
        if (i < len-1)
        {
            cout << ", ";
        }
    }
    cout << "]" << endl;
}

int main()
{
    int a[] = {1,2,3,4,5,6,7,8};
    int b[8];
    copy(a, a+8, b);
    reverse(a, a+8);
    int *val = find(a, a+8, 4);
    
    cout << "数组 a：";
    display_array(a, 8);
    cout << "数组 b：";
    display_array(b, 8);
    return 0;
}